package com.zmn.oms.persistence.interfaces.ins;

import com.zmn.oms.model.entity.ins.InsOrderMasterSync;
import org.apache.ibatis.annotations.Param;

import java.util.List;

/**
 * 类描述：保险单
 *
 * @author liuying
 * @date 2019/01/23 10:12
 */
public interface InsOrderMasterSyncDao {

    /**
     * 查询未同步的数据
     * @return
     */
    List<InsOrderMasterSync> listNoSynced(Integer rows);

    /**
     * 修改同步状态为同步中
     * @param insMasterSyncIdList
     */
    void updateSyncPendingByKeys(@Param("insMasterSyncIdList") List<Long> insMasterSyncIdList);

    /**
     * 修改同步状态为未同步
     * @param insMasterSyncIdList
     */
    void updateUnSyncedByKeys(@Param("insMasterSyncIdList") List<Long> insMasterSyncIdList);

    /**
     * 修改同步状态
     * @param insMasterSyncIdList
     */
    void updateSyncedSuccessByKeys(@Param("insMasterSyncIdList") List<Long> insMasterSyncIdList);

    /**
     * 修改同步状态
     * @param insMasterSyncIdList
     */
    void updateSyncedFailByKeys(@Param("insMasterSyncIdList") List<Long> insMasterSyncIdList);

    /**
     * 添加
     * @param insOrderMasterSync
     * @return
     */
    int insertInsOrderMasterSync(InsOrderMasterSync insOrderMasterSync);
}